
<!DOCTYPE html>
<html>
<head>
<meta name="renderer" content="webkit|ie-comp|ie-stand">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>

<link rel="stylesheet" type="text/css" href="theme/layui/css/layui.css">
<link rel="stylesheet" type="text/css" href="theme/default/css/common.css">
<script src="theme/default/Js/Common.js"></script>
<script src="theme/default/Js/jquery-3.0.0.min.js"></script>
<script src="theme/default/js/artDialog.js?skin=blue"></script>
<link rel="stylesheet" type="text/css" href="include/webupload/webuploader.css">
<script src="include/webupload/webuploader.min.js"></script> 
<script src="include/webupload/uploads.js"></script>
<link rel='stylesheet' type="text/css" href='theme/desktop/css/font-awesome.min.css'>
<link rel="stylesheet" type="text/css" href="theme/desktop/css/desktop.css">

</head>
<body>

<script>
//显示
var funxs=function(){
	
var okon = document.getElementsByClassName('okon');
for (i = 0; i <= okon.length; i++) {
    //alert(i)
    if (okon[i].checked) {
        okon[i].parentNode.className = "okon_on";
    } else {
        okon[i].parentNode.className = "okonno";
    }
    okon[i].onclick = function() {
        if (this.checked) {
            this.parentNode.className = "okon_on";
        } else {
            this.parentNode.className = "okonno";
        }
    }
}	
	
}
//必填	
var funbt=function(){
	
var okon_bt = document.getElementsByClassName('okon_bt');
for (i = 0; i <= okon_bt.length; i++) {
    //alert(i)
    if (okon_bt[i].checked) {
        okon_bt[i].parentNode.className = "okon_on";
    } else {
        okon_bt[i].parentNode.className = "okonno";
    }
    okon_bt[i].onclick = function() {
        if (this.checked) {
            this.parentNode.className = "okon_on";
        } else {
            this.parentNode.className = "okonno";
        }
    }
}	
	
	
}
//隐藏	
var funyc=function(){
	
var okon_yc = document.getElementsByClassName('okon_yc');
for (i = 0; i <= okon_yc.length; i++) {
    //alert(i)
    if (okon_yc[i].checked) {
        okon_yc[i].parentNode.className = "okon_on";
    } else {
        okon_yc[i].parentNode.className = "okonno";
    }
    okon_yc[i].onclick = function() {
        if (this.checked) {
            this.parentNode.className = "okon_on";
        } else {
            this.parentNode.className = "okonno";
        }
    }
}	
	
}
//权限	
var funqx=function(){
	
var qxon = document.getElementsByClassName('qxon');
for (i = 0; i <= qxon.length; i++) {
    //alert(i)
    if (qxon[i].checked) {
        qxon[i].parentNode.className = "qxyes";
    } else {
        qxon[i].parentNode.className = "qxno";
    }
    qxon[i].onclick = function() {
        if (this.checked) {
            this.parentNode.className = "qxyes";
        } else {
            this.parentNode.className = "qxno";
        }
    }
}	
	
	
}
</script>

<script>
	<!-- 必填项提示
	function CheckInput()
	{
		if(document.getElementById('account').value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '登录账号不能为空!'});document.getElementById('account').focus();return false;}
		if(document.getElementById('name').value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '真实姓名不能为空!'});document.getElementById('name').focus();return false;}
		if(document.getElementById('password').value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '登录密码不能为空!'});document.getElementById('password').focus();return false;}
		if(document.getElementById('password').value != document.getElementById('confirmPWS').value){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '两次输入的密码不一样!'});document.getElementById('password').focus();return false;}
		if(document.getElementById('level').value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '职位&权限不能为空!'});document.getElementById('level').focus();return false;}
		if(document.getElementById('group').value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '所在部门不能为空!'});document.getElementById('group').focus();return false;}
		if(document.getElementById('Mobile').value == ""){art.dialog({title: 'Error',time: 1,icon: 'warning',content: '手机号码不能为空!'});document.getElementById('Mobile').focus();return false;}
	}
	-->
	</script>

<div class="fixed_bg_T">
  <div class="MenuboxS">
    <ul>
      <li class="hover"><span><a href="?action=User&stype=Edit&sstype=Main&ID=3">员工档案</a></dd></li>
        <li ><span><a href="?action=User&stype=Edit&sstype=Manage&ID=3">管理范围</a></dd></li>
        <li ><span><a href="?action=User&stype=Edit&sstype=Level&ID=3">详细权限</a></span></li>
    </ul>
    <div class="clear"></div>
  </div>
</DIV>

<!----------------------------------------新增员工开始----------------------------------------> 
<!----------------------------------------新增员工开始---------------------------------------->
<div class="cssout">
  <form class="layui-form" name="save" action="usersave.asp?action=User&stype=saveEdit&LaiLu=" method="post" onSubmit="return CheckInput();">
    <div class="cssin">
      <ul>
        <li class="w100 bg"><dd class="isin"><B>基本信息</B></dd></li>
        
        <!--line-->
        <li class="w12 bg cl tr"><dd class="isin"><font color="#FF0000">*</font> 登录账号</dd></li>
        <li class="w38"><dd class="isin"> qq123456</dd></li>
        <li class="w12 bg tr"><dd class="isin"><font color="#FF0000">*</font> 真实姓名</dd></li>
        <li class="w38"><dd class="isin">
          <input name="name" type="text" class="bor int" id="name" size="30" maxlength="30" value="测试" >
          <span class="info_help vtip" title="更新所有记录,慎重!"></span></dd>
        <!--end--> 
        
        <!--line-->
        <li class="w12 bg cl tr"><dd class="isin"><font color="#FF0000">*</font> 登录密码</dd></li>
        <li class="w38"><dd class="isin">
          <input name="password" type="password" class="bor int" id="password" size="30" maxlength="30" >
          <span class="bxgqlk">不修改请留空！</span> </dd></li>
        <li class="w12 bg tr"><dd class="isin"><font color="#FF0000">*</font> 重复密码</dd></li>
        <li class="w38"><dd class="isin">
          <input name="confirmPWS" type="password" class="bor int" id="confirmPWS" size="30" maxlength="30" > <span class="bxgqlk">不修改请留空！</span>
        </dd></li>
        <!--end--> 
        
        <!--line-->
        
        
        <li class="w12 bg cl tr"><dd class="isin"><font color="#FF0000">*</font> 所在部门</dd></li>
        <li class="w38"><dd class="isin">
          <select name='group' id='group' class='int' style='border:1px solid #f00;'><option value="">请选择</option><option value="1">总经办</option><option value="2">财务部</option><option value="3" selected>业务一部</option><option value="4">业务二部</option><option value="5">渠道招商部</option><option value="6">客服部</option></select></dd></li>
        <li class="w12 bg tr"><dd class="isin"><font color="#FF0000">*</font> 职位&权限</dd></li>
        <li class="w38"><dd class="isin">
          <select name='level' id='level' class='int' style='border:1px solid #f00;'><option value="">请选择</option><option value="99" selected>超级管理员</option><option value="89">总经理</option><option value="88">销售经理</option><option value="87">销售员</option><option value="86">财务主管</option><option value="85">售后专员</option><option value="84">6666</option><option value="83">faf</option></select></dd></li>
        
        <!--end--> 
        
        <!--line-->
        <li class="w12 bg cl tr"><dd class="isin"><font color="#FF0000">*</font> 手机号码</dd></li>
        <li class="w38"><dd class="isin">
          <input name="Mobile" type="text" class="bor int" id="Mobile" size="30" maxlength="30" value="15017788000">
        </dd></li>
        <li class="w12 bg tr"><dd class="isin"> E-mail</dd></li>
        <li class="w38"><dd class="isin">
          <input name="Email" type="text" class="bor int" id="Email" size="30" value=""></dd>
          </li>
        <!--end--> 
        
        <!--line-->
        <li class="w12 bg cl tr"><dd class="isin"> 客户数量限制</li>
        <li class="w38"><dd class="isin">
          <input name="maxnum" type="text" class="bor int" id="maxnum" value="0" size="20">
          <span class="info_help vtip" title="最大客户数量限制,默认0为不限制"></span></dd></li>
          
        <li class="w12 bg tr"><dd class="isin">员工提成</dd></li>
        <li class="w38"><dd class="isin">
          <input name="percent" type="text" class="bor int" id="percent" onKeyUp="checkpercent()" value="0" size="6" maxlength="10">
          % (允许数值为0.01%~100%) </dd></li>
        <!--end--> 
        
        <li class="w12 bg duohang cl tr"><dd class="isin" style="line-height:85px;">头像</dd></li>
        <li class="w38 duohang"><dd class="isin" style=" padding-top:22px;">
          <input name="avatar" id="avatar" type="hidden" class="btns" value="/theme/default/images/avatar.jpg" size="30">
          
<span id="name1"> </span>
<script>
//定义一个上传
var upName1 = $("#name1").powerWebUpload(
{ 
	auto: true,//上传后是否自动上传
	fileNumLimit:1,//允许上传个数
	accept: {
	   title: '上传文件',
	   extensions: 'gif,jpg,png,bmp,doc,docx,xls,xlsx,ppt,pdf,rar,zip,txt',//允许类型 原始：'gif,jpg,jpeg,bmp,png'
	   mimeTypes: '*'//类型 原始：'image/*'
	}//限制的配置信息
});
//绑定上传完成事件 file 参数中有 原始名称 大小 后缀 类型等等参数；percentage是服务返回的参数 有信息 和图片地址
    upName1.on('uploadSuccess', function (file, percentage) {
	$("#avatar").val(percentage.data.src);
	$("#logoimg").attr('src',percentage.data.src); 
	
});
</script>
        </dd></li>
        <!--end--> 
      
        
        <!--line-->
        <li class="w12 bg duohang tr"><dd class="isin" style="line-height:85px;">头像预览</dd></li>
        <li class="w38 duohang"><dd class="isin" style="line-height:85px;"> <img src="theme/default/images/avatar.jpg" height="70" class="utouxiang" id="logoimg" /> </dd></li>
        <!--end--> 
        
        
<div id="user_btn" class="user_gb"><span>展开用户详细信息</span></div>
        
<div id="user_xx" style="display:none;">
    
        
        <!--line-->
        <li class="w12 bg tr none"><dd class="isin">员工分组</dd></li>
        <li class="w38 none"><dd class="isin">
          <select name='Xiaozu' id='Xiaozu' class='int' style='border:1px solid #f00;'><option value="">请选择</option></select>
          <a class="button_top_set" onclick='Xiaozu_add("xiaozu.asp?action=Xiaozusave&sstype=xiaozu&stype=add&LaiLu=")'>新增小组</a>
          
          <script>function Xiaozu_add(Dourl) {$.dialog.open(Dourl, {title: '新增小组', width: 400, height: 170,fixed: true}); };</script> 
        </dd></li>
        <!--end--> 
        
        <!--line-->
        <li class="w12 bg cl tr"><dd class="isin">性别</dd></li>
        <li class="w38"><dd class="isin">
          <input name="usex" class="btns" type="radio" value="1"checked title="男">
          <input name="usex" class="btns" type="radio" value="0" title="女">
        </dd></li>
        <li class="w12 bg tr"><dd class="isin">身份证号</dd></li>
        <li class="w38"><dd class="isin">
          <input name="usfzh" type="text" class="bor int" id="usfzh" size="45" value=""></dd>
          </li>
        <!--end--> 
        
        <!--line-->
        <li class="w12 bg cl tr"><dd class="isin">生日</dd></li>
        <li class="w38"><dd class="isin">
          <input name="Birthday" type="text" id="Birthday" class="int Wdate" size="20" onFocus="WdatePicker({dateFmt:'yyyy-MM-dd'})" value="">
        </dd></li>
        <li class="w12 bg tr"><dd class="isin">入司时间</dd></li>
        <li class="w38"><dd class="isin">
          <input name="addtime" type="text" id="addtime" class="int Wdate" size="20" onFocus="WdatePicker({dateFmt:'yyyy-MM-dd'})" value=""></dd>
          </li>
        <!--end--> 
        
        <!--line-->
        <li class="w12 bg cl tr"><dd class="isin">家乡</dd></li>
        <li class="w38"><dd class="isin">
          <input name="ujiaxiang" type="text" class="bor int" id="ujiaxiang" size="30" value="" />
        </dd></li>
        <li class="w12 bg tr"><dd class="isin">家庭住址</dd></li>
        <li class="w38"><dd class="isin">
          <input name="ujtzz" type="text" class="bor int" id="ujtzz" size="45" value=""></dd>
          </li>
        <!--end--> 
        
        <!--line-->
        <li class="w12 bg cl tr"><dd class="isin">紧急联系人</dd></li>
        <li class="w38"><dd class="isin">
          <input name="ujjlxr" type="text" class="bor int" id="ujjlxr" size="30" value="">
        </dd></li>
        <li class="w12 bg tr"><dd class="isin">紧急联系人电话</dd></li>
        <li class="w38"><dd class="isin">
          <input name="ujjlxrhm" type="text" class="bor int" id="ujjlxrhm" size="30" value=""></dd>
          </li>
        <!--end--> 
        
        <!--line-->
        <li class="w12 bg cl tr"><dd class="isin">签名</dd></li>
        <li class="w38"><dd class="isin">
          <input name="sign" type="text" class="bor int" id="sign" size="45" value="">
        </dd></li>
        
       
        
        <!--line-->
        <li class="w12 bg cl duohang tr"><dd class="isin">个人介绍</dd></li>
        <li class="w88 duohang"><dd class="isin">
          <textarea name="uinfo" rows="4" id="uinfo" style="height:65px;width:98%;"></textarea></dd>
        </li>
        <!--end--> 
        
        <!--line-->
        <li class="w12 bg cl tr"><dd class="isin">离职状态</dd></li>
        <li class="w38"><dd class="isin">
          <label>
            <input name="ulzzt" type="checkbox" id="ulzzt" value="1"  />
            已离职</label>
        </dd></li>
        <li class="w12 bg tr"><dd class="isin">离职时间</dd></li>
        <li class="w38"><dd class="isin">
          <input name="ulzsj" type="text" id="ulzsj" class="int Wdate" size="20" onFocus="WdatePicker()" value=""></dd>
          </li>
        <!--end--> 
        
        <!--line-->
        <li class="w12 bg cl duohang tr"><dd class="isin">离职原因</dd></li>
        <li class="w88 duohang"><dd class="isin">
          <textarea name="ulzyy" rows="4" id="ulzyy" style="height:65px;width:98%;"></textarea></dd>
        </li>
        
</div>
<script>
$("#user_btn").click(function(){
  var zt=$(this).attr("class")
  if(zt=="user_gb"){
  $('#user_btn').removeClass('user_gb').addClass('user_zk');
  $("#user_btn span").text("收起用户详细信息");
  $("#user_xx").css("display","block");
  }else{
  $('#user_btn').removeClass('user_zk').addClass('user_gb');
  $("#user_btn span").text("展开用户详细信息");
  $("#user_xx").css("display","none");
  }
  
});
</script> 
        
        <div class="clear"></div>  
      </ul>
    </div>
    <div class="h50b"></div>
    <div class="fixed_bg_B">
      <input name="uid" type="hidden" id="uid" value="3">
      <input name="OldName" type="hidden" id="OldName" value="测试">
      <input type="submit" name="Submit" class="btn2 btnbaoc" value="保存">
      <input name="Back" type="button" id="Back" class="btn2 btnguanb" value="关闭" onClick="art.dialog.close();guanbi();">
    </div>
  </form>
</div>

<script src="theme/default/WdatePicker.js"></script> 
<script src="theme/layui/layui.js"></script> 
<script src="theme/desktop/js/common.js"></script>

<script>
/*弹出窗口封装代码*/
$(".open-app").on("click",function(){
	var width = $(this).data("width")?$(this).data("width"):900,//获得宽度
	height = $(this).data("height")?$(this).data("height"):400//获得高度
	url = $(this).attr("href")//获得打开URL
	title = $(this).attr("title");//获得标题	
	$.dialog.open(url, {title: title, width:width,height:height, fixed: true});
	return false;	
})
</script>

</body>
</html>
